package com.wlcorp.forcazamis.domain.storagein;

import java.util.Date;
import java.util.Set;

import com.wlcorp.forcazamis.domain.confirm.Confirm;
import com.wlcorp.forcazamis.domain.system.Staff;
import com.wlcorp.forcazamis.sys.BaseBean;
import com.wlcorp.forcazamis.sys.util.AppConstant;

public class StorageIn extends BaseBean {
	private static final long serialVersionUID = -4012369658529260603L;
	private Long storageInId;
	private Staff submiter;
	private Long submiterId;
	private Confirm confirm;
	private Long confirmId;
	private Date inStorageDate;
	private Integer state;
	private String memo;
	private Integer type;
	private Set<?> storageInSampleSet;
	private boolean deleteFlag;

	public boolean isDeleteFlag() {
		return deleteFlag;
	}

	public void setDeleteFlag(boolean deleteFlag) {
		this.deleteFlag = deleteFlag;
	}

	public Confirm getConfirm() {
		return confirm;
	}

	public void setConfirm(Confirm confirm) {
		this.confirm = confirm;
	}

	public Long getConfirmId() {
		return confirmId;
	}

	public void setConfirmId(Long confirmId) {
		this.confirmId = confirmId;
	}

	public Date getInStorageDate() {
		return inStorageDate;
	}

	public void setInStorageDate(Date inStorageDate) {
		this.inStorageDate = inStorageDate;
	}

	public String getMemo() {
		return memo;
	}

	public void setMemo(String memo) {
		this.memo = memo;
	}

	public Integer getState() {
		return state;
	}

	public void setState(Integer state) {
		this.state = state;
	}

	public Long getStorageInId() {
		return storageInId;
	}

	public void setStorageInId(Long storageInId) {
		this.storageInId = storageInId;
	}

	public Staff getSubmiter() {
		return submiter;
	}

	public void setSubmiter(Staff submiter) {
		this.submiter = submiter;
	}

	public Long getSubmiterId() {
		return submiterId;
	}

	public void setSubmiterId(Long submiterId) {
		this.submiterId = submiterId;
	}

	public Integer getType() {
		return type;
	}

	public void setType(Integer type) {
		this.type = type;
	}

	public Set<?> getStorageInSampleSet() {
		return storageInSampleSet;
	}

	public void setStorageInSampleSet(Set<?> storageInSampleSet) {
		this.storageInSampleSet = storageInSampleSet;
	}

	public String getTypeName() {
		String typeName = "";
		if (AppConstant.STORAGE_IN_TYPE_DIRECT_BUY == type) {
			typeName = "直接买样";
		} else if (AppConstant.STORAGE_IN_TYPE_FROM_CUSTOMER == type) {
			typeName = "客户来样";
		} else if (AppConstant.STORAGE_IN_TYPE_FROM_FACTORY == type) {
			typeName = "工厂来样";
		} else if (AppConstant.STORAGE_IN_TYPE_OUT_GOODS == type) {
			typeName = "出货样";
		} else if (AppConstant.STORAGE_IN_TYPE_DRAW_DESIGN == type) {
			typeName = "打样单";
		} else if (AppConstant.STORAGE_IN_TYPE_EXHIBIT == type) {
			typeName = "参展";
		} else if (AppConstant.STORAGE_IN_TYPE_CHECK == type) {
			typeName = "盘点";
		} else if (AppConstant.STORAGE_IN_TYPE_FACTORY_T == type) {
			typeName = "工厂淘样";
		} else if (AppConstant.STORAGE_IN_TYPE_OTHER == type) {
			typeName = "其他";
		}
		return typeName;
	}

	public String getStateName() {
		String stateName = "";
		if (AppConstant.BILL_STATE_SUBMITED == state) {
			stateName = "编辑中";
		} else if (AppConstant.BILL_STATE_PRE_CONFIRM == state) {
			stateName = "审批中";
		} else if (AppConstant.BILL_STATE_CONFIRMED == state) {
			stateName = "审批完成";
		} else if (AppConstant.BILL_STATE_DRAWBACK == state) {
			stateName = "已退单";
		}
		return stateName;
	}
}
